package algorithm.poj.p2000;

import java.io.BufferedReader;
import java.io.File;
import java.io.FileInputStream;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLDecoder;
import java.util.HashMap;
import java.util.Map;
import java.util.StringTokenizer;

/**
 * 分析：same as POJ1118
 * 实现：
 * 经验：
 * 教训：
 * 
 * 
 * @author wong.tong@gmail.com
 *
 */
public class P2606 {

	public static void main(String[] args) throws Exception {

		InputStream input = null;
		if (false) {
			input = System.in;
		} else {
			URL url = P2606.class.getResource("P2606.txt");
			File file = new File(URLDecoder.decode(url.getPath(), "UTF-8"));
			input = new FileInputStream(file);
		}
		
		BufferedReader stdin = new BufferedReader(new InputStreamReader(input));

		String line = stdin.readLine();
		int N = Integer.valueOf(line.trim());
		Point[] ps = new Point[N];
		int max = 0;
		for (int i = 0; i < N; i ++) {
			line = stdin.readLine();
			ps[i] = new Point(line);
			Map<Direction, Integer> dirs = new HashMap<Direction, Integer>();
			for (int j = 0; j < i; j ++) {
				int dx = ps[i].x-ps[j].x;
				int dy = ps[i].y-ps[j].y;
				if (dx == 0 && dy == 0) {
					//do nothing
				} else {
					Direction dir = new Direction(dx, dy);
					if (!dirs.containsKey(dir)) {
						dirs.put(dir, 0);
					}
					int c = dirs.get(dir);
					dirs.put(dir, c+1);
				}
			}
			for (Direction dir: dirs.keySet()) {
				if (dirs.get(dir) > max) {
					max = dirs.get(dir);
				}
			}
		}
		System.out.println(max+1);
	}
	
	private static class Point {
		
		int x;
		int y;
		
		public Point(String str) {
			StringTokenizer st = new StringTokenizer(str);
			this.x = Integer.valueOf(st.nextToken());
			this.y = Integer.valueOf(st.nextToken());
		}
		public String toString() {
			return "P[" + this.x + ", " + this.y + "]";
		}
	}
	
	private static class Direction {
		
		int x;
		int y;
		
		public Direction(int x, int y) {
			
			int d = gcd(x, y);
			this.x = x/d;
			this.y = y/d;
			if (this.x < 0) {
				this.x = -this.x;
				this.y = -this.y;
			}
		}
		
		public int hashCode() {
			return (int)(x*1031+y);
		}
		
		private int gcd(int x, int y) {

			x = (x<0)?(-x):x;
			y = (y<0)?(-y):y;
			if (x == 0) {
				return y;
			} else if (y == 0) {
				return x;
			} else {
				if (x < y) return gcd(y, x);
				else return gcd(y, x%y);
			}
		}
		
		public boolean equals(Object obj) {
			if (obj == null || !(obj instanceof Direction)) {
				return false;
			} else {
				Direction dir = (Direction)obj;
				return x == dir.x && (y == dir.y || y == -dir.y);
			}
		}
		
		public String toString() {
			return "D[" + this.x + "," + this.y +"]";
		}
	}
}